var UtilFunctions = {
	_item: null,
	inject: function(item) {
		this._item = item;
	},
	isValue: function() {
		return typeof this._item.type == "undefined";
	},
	isEntity: function() {
		return !this.isValue();
	},
	type: function() {
		return isEntity() ? "entity" : "value";
	}
};
var injectUtilFunctions = function(item) {
	var item = item;
}
function isValue(item) {
	return typeof item.type == "undefined";
}

function isEntity(item) {
	return !isValue(item);
}

function type(item) {
	return isEntity(item) ? "entity" : "value";
}

function actualType(item) {
	return item.entity;
}

function isString(item) {
	return typeof item == "string";
}

function imageUrl(size, item) {
	// Person:  actions/contact-new-3.png
	// Entity:  
	// Course:  
	return "assets/images/icons/" + size + "/" + actualType(item) + ".png";
}

function shortHTMLText(item) {
	return isValue(item) ? item["value"] : "<span class=\"important\">" +
		item["all"] + "</span>";
}
